*{
  padding: 0;
  margin: 0;
}
html,body{
  position: relative;
  width: 100%;
  height: 100%;
  font-size: 0.729vw;// 1rem = 10px
}
body{
  //background-image: linear-gradient(330deg, rgba(6, 73, 144, 0.7) 0%, rgba(12, 161, 240, 0.7) 100%);
  background: #fff;
}
.index-body{
  height: auto;
  background-image: none;
}
#app{
  position: relative;
  width: 100%;
  height: 100%;
}
:root {
  --primary-color: #0674f5;
  --primary-color-light: #2576f5;
  --ai-color-high: #BD3124;
  --ai-color-high-hover: #9a281e;
}
.fb{
  font-family: PingFangSC-bold;
  font-weight: 700;
}
.high-span{
  position: relative !important;
}
.high-btn{
  position: relative;
  height: 32px;
  line-height: 32px;
  padding: 0px 15px;
  color: #fff;
  background: var(--ai-color-high);
  border-radius: 4px;
  font-size: 1.4rem;
  display: inline-block;
  cursor: pointer;
  &:hover{
    background: var(--ai-color-high-hover);
  }
}
.flex{
  display: flex;
}
.just-between{
  justify-content: space-between;
}
.align-center{
  align-items: center;
}
.el-card{
  margin-top: 20px;
}
.el-tag{
  background-color: rgb(85,149,197) !important;
  color: var(--el-text-color-secondary) !important;
  .el-tag__close:hover{
    background-color: rgb(62, 107, 141) !important;
  }
}
.is-current>.el-tree-node__content {
  background-color: var(--el-tree-node-hover-bg-color);
}
.el-tooltip__trigger{
  &:focus-visible{
    outline: none !important;
    border: none !important;
  }
}
.think-tank-page{
  .el-progress-bar__outer{
    background-color: rgb(85,149,197);
    overflow: unset;
  }
  .el-progress-bar__innerText{
    background-color: var(--el-text-color-secondary);
    color: var(--el-color-primary);
    border-radius: 10px;
    padding: 2px 5px;
    margin: -8px 0 0;
  }
}
.circle-input{
  .el-input__wrapper{
    border-radius: 30px;
  }
}
.underline-input{
  .el-input__wrapper,.el-input__wrapper:hover,.el-input__wrapper.is-focus{
    border-top: none;
    border-left: none;
    border-right: none;
    background: none;
    border-radius: 0;
    box-shadow: none;
    border-bottom: 1px solid var(--primary-color);
  }
}

@-webkit-keyframes loading-rotate {
  0%{
    -webkit-transform: rotate3d(0, 0, 1, 0deg);
  }
  100%{
    -webkit-transform: rotate3d(0, 0, 1, 360deg);
  }
}
@keyframes loading-rotate {
  0%{
    transform: rotate3d(0, 0, 1, 0deg);
  }
  100%{
    transform: rotate3d(0, 0, 1, 360deg);
  }
}
.loading{
  display: inline-block;
  animation: loading-rotate 1s linear infinite;
}
.success-text{
  color: var(--el-color-primary);
}
.grey-text{
  color: var(--el-text-color-disabled);
}
.error-text{
  color: var(--el-color-error);
}
.token-text{
  white-space: pre-wrap;
  word-break: break-all;
}
.card-header{
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  .card-title{
    font-size: 1.2rem;
  }
  .conditions{
    position: relative;
    display: flex;
    align-items: center;
    .condition-item{
      display: flex;
      align-items: center;
      margin-left: 20px;
    }
    span{
      white-space: nowrap;
    }
    .el-select{
      width: 140px;
      margin-right: 20px;
    }
  }
}
@media only screen and (max-width: 1080px) {
  .header-wrapper{
    height: 5.6rem !important;
    .logo-title{
      font-size: 2.2rem !important;
    }
    .link-btn{
      font-size: 2.2rem !important;
    }
  }
}
@media only screen and (max-width: 720px) {
  .header-wrapper{
    height: 6.6rem !important;
    .logo-title{
      font-size: 2.8rem !important;
    }
    .link-btn{
      font-size: 2.8rem !important;
    }
  }
}
.scrollbar-y{
  overflow-y: hidden;
  //scrollbar-width: thin;
  //scrollbar-color: rgba(0,0,0,0.2) rgba(0,0,0,0.1);
  scrollbar-gutter: stable;
  -webkit-overflow-scrolling: touch;
  &:hover{
    overflow-y: overlay;
  }
  &::-webkit-scrollbar {
    width: 5px; // 设置成0滚动条会因为设置了scrollTop暂歇性的无法滚动
  }
  /* 设置滚动条背景色 */
  &::-webkit-scrollbar-track{
    //background: rgba(0, 0, 0, 0.1);
    background: rgba(0, 0, 0, 0);
    border-radius: 3px;
  }
  /*滚动条里面小方块背景色*/
  &::-webkit-scrollbar-thumb {
    //background:rgba(0,0,0,0.3);
    background:rgba(0,0,0,0);
    border-radius: 3px;
  }
}
.el-header .menu-box, .el-footer .footer-content, .user-page,.ai-search-page{
  width: 70%;
  margin: auto;
}
.index-body::-webkit-scrollbar {
  width: 0px;
}
.my-upload-item{
  position: relative;
  input{
    opacity: 0;
    width: 100%;
    height: 100%;
    position: absolute;
    top:0;
    left:0;
    z-index: 1;
  }
}
.link-btn{
  color: #fff;
  font-family: PingFangSC-bold;
  font-size: 1.2rem;
  padding: 0 5px;
  cursor: pointer;
}
.gradient-text{
  color: transparent;
  -webkit-background-clip: text;
}
.ai-text{
  ul, ol{
    padding-left: 2rem;
  }
}
.header-search-input{
  .el-input__wrapper{
    border-radius: 30px;
    //background-color: #f4f5f7;
  }
}
.search-history-card{
  .el-card__body{
    height: 100%;
    padding-top: 0;
    padding-bottom: 0;
    @extend .scrollbar-y;
  }
}
.search-chat-card{
  position: relative;
  border-radius: 3px;
  //border: 1px solid rgba(0,0,0,0.1);
  height: 100%;
  padding: 0;
  //background: #f4f5f7;
  .answer-content{
    @extend .scrollbar-y;
  }
}
.ai-search-page{
  .input-box{
    .el-textarea__inner{
      padding: 0.5rem 0.5rem 3.6rem 0.5rem;
      box-sizing: border-box;
    }
  }
}
.sci-hot-page{
  .hot-list{
    @extend .scrollbar-y;
  }
}
.pcenter-page{
  .form-card{
    .el-card__body{
      height: calc(100% - 110px);
      @extend .scrollbar-y;
    }
  }
}
.think-tank-page{
  .el-tree-node__content{
    height: 2.4rem;
    border-radius: 3px;
  }
}

$avatar-bg-size: 3.4rem;
.ai-search-page {
  position: relative;
  height: 100%;
  display: flex;
  justify-content: space-between;
}



.search-chat-card {
  position: relative;
  width: 100%;

  .answer-content {
    position: relative;
    width: 100%;
    max-height: calc(100% - 134px);
    font-size: 1.2rem;
  }
  .answer-content_files{
    max-height: calc(100% - 202px);
  }
  .chat-item{
    position: relative;
    padding: 3.5rem 1rem;
    .user-content{
      position: relative;
      width: 100%;
      display: flex;
      justify-content: flex-end;
      .user-avatar{
        position: relative;
        width: $avatar-bg-size;
        min-width: $avatar-bg-size;
        height: $avatar-bg-size;
        border-radius: $avatar-bg-size;
        margin-right: 1.2rem;
        background: #fff;
        .avatar{
          position: absolute;
          top: 15%;
          left: 15%;
          width: 70%;
          height: 70%;
          border-radius: $avatar-bg-size;
          background-size: 100% 100%;
        }
      }
      .user-text{
        position: relative;
        background: var(--el-color-primary);
        color: #fff;
        padding: 2px 8px;
        border-radius: 5px;
        line-height: 2rem;
        font-size: 1rem;
        .iconfont{
          position: absolute;
          font-size: 1.4rem;
          height: 1.4rem;
          color: var(--el-color-success-light-3);
          top: 1.7rem;
          margin-top: -0.7rem;
          left: -1.2rem;
          line-height: 1.4rem;
          transform: rotateZ(-180deg);
          transform-origin: center;
        }
      }
    }
    .aispire-content{
      position: relative;
      display: flex;
      width: 100%;
      align-items: flex-start;
      margin-top: 2rem;
      font-size: 1rem;
      .icon-jiazaizhong{
        display: inline-block;
        transform-origin: center;
        font-size: 2.4rem;
        width: 2.4rem;
        height: 2.4rem;
      }
      .ai-avatar{
        position: relative;
        width: $avatar-bg-size;
        min-width: $avatar-bg-size;
        height: $avatar-bg-size;
        border-radius: $avatar-bg-size;
        margin-right: 1.2rem;
        background: #2d93c7;
        .avatar{
          position: absolute;
          top: 15%;
          left: 15%;
          width: 70%;
          height: 70%;
          //border-radius: $avatar-bg-size;
          background-image: url("../../assets/images/logo2.png");
          background-size: 100% 100%;
        }
      }
      .ai-text{
        position: relative;
        //background: #2d93c7;
        background: #fff;
        color: #333;
        //padding: 8px;
        border-radius: 5px;
        line-height: 1.6rem;
        padding: 1rem;
        width: 100%;
        .reasoning-box{
          position: relative;
          padding: 1rem;
          //background: #188699;
          //color: #dddbdb;
          background: #f3f5fc;
          //color: #595959;
          border-radius: 5px;
          margin-bottom: 1.4rem;
          overflow: hidden;
          height: 2rem;
          .thinking-box{
            position: relative;
            display: flex;
            align-items: center;
            font-size: 1rem;
            height: 2rem;
          }
          .thinking-text{
            margin-top: 0.5rem;
            font-size: 1rem;
            line-height: 1.6rem;
            display: none;
          }
          .arrow-icon{
            position: absolute;
            cursor: pointer;
            top:1.2rem;
            right:1rem;
            transition: all 0.2s linear;
            transform: rotateZ(180deg);
          }
          &.expand{
            height: auto;
            .thinking-text{
              display: block;
            }
            .arrow-icon{
              transform: rotateZ(0deg);
            }
          }
        }
        .icon-tuili-copy,.icon-duigouwancheng{
          font-size: 1.6rem;
          margin-right: 8px;
          color: var(--primary-color);
        }
        .opt-box{
          position: absolute;
          bottom: -35px;
          left: 0px;
          display: flex;
          align-items: center;
          font-size: 1rem;
          color: var(--el-text-color-disabled);
          .opt-item{
            display: flex;
            align-items: center;
            cursor: pointer;
            padding: 0px 5px;
            border-radius: 3px;
            white-space: nowrap;
            &:hover{
              background: rgb(85,149,197);
            }
          }
          .iconfont{
            font-size: 1.6rem;
          }
        }
      }
    }
  }

  .input-box {
    position: absolute;
    bottom: 0;
    width: calc(100% - 40px);
    padding: 20px 20px 20px;

    .el-button+.el-button {
      margin-left: 12px;
    }
    .lf-box,.rt-box{
      position: relative;
      display: flex;
      align-items: center;
      .el-switch{
        margin-left: 10px;
      }
    }
    .icon-wangluo{
      font-size: 1.4rem;
    }
    .upload-file-item{
      margin: 0 12px;
      .icon-jiazaizhong{
        font-size: 2rem;
      }
    }
    .icon-fujian{
      display: inline-block;
      cursor: pointer;
      font-size: 2.0rem;
      &:hover{
        color: var(--primary-color);
      }
      &.disabled{
        cursor: not-allowed;
        color: var(--el-text-color-disabled);
      }
    }
    .new-topic-btn{
      position: absolute;
      top: 20px;
      left: 50%;
      margin-left: 0;
      transform: translateX(-50%);
    }
    .option-box{
      position: absolute;
      bottom: 25px;
      display: flex;
      justify-content: space-between;
      width: calc(100% - 60px);
      padding: 0 10px;
      left: 20px;
    }
    .option-box_file{
      bottom: 88px;
    }
    .llm-item{
      .el-button{
        width: 120px;
      }
    }
    .file-content{
      position: relative;
      padding: 10px;
      display: flex;
      flex-wrap: wrap;
      gap: 8px;
      max-height: 42px;
      background: rgb(85,149,197);
      border-radius: 3px;
      .file-item{
        position: relative;
        width: calc((100% - 16px) / 3);
        box-sizing: border-box;
        display: flex;
        padding: 5px;
        border-radius: 5px;
        box-shadow: 0px 0px 5px rgb(62, 107, 141);
        background: rgb(62, 107, 141);
      }
      .file-icon{
        position: relative;
        text-align: center;
        padding: 2px;
        width: 32px;
        height: 32px;
        .icon{
          position: relative;
          width: 100%;
          height: 100%;
          background-size: 100% 100%;
          background-repeat: no-repeat;
          margin-right: 5px;
        }
        .image-icon{
          background-image: url("../../assets/images/image-icon.png");
        }
        .excel-icon{
          background-image: url("../../assets/images/excel-icon.png");
        }
        .txt-icon{
          background-image: url("../../assets/images/txt-icon.png");
        }
        .pdf-icon{
          background-image: url("../../assets/images/pdf-icon.png");
        }
        .word-icon{
          background-image: url("../../assets/images/word-icon.png");
        }
      }
      .file-info{
        display: flex;
        flex-direction: column;
        font-size: 1rem;
        justify-content: space-around;
      }
      .icon-shanchu3{
        position: absolute;
        font-size: 1.6rem;
        cursor: pointer;
        right: 2px;
        top: 2px;
        color: var(--el-color-error);
      }
    }
  }
}

